<!--
 * @Description  : 修改
 * @Author       : zhao
 * @Date         : 2022-07-25 14:32:06
 * @LastEditors  : zhao
 * @LastEditTime : 2022-07-25 17:28:25
-->

<template>
    <div class='modify'>
        <el-button type="primary" size="default" @click="modify()">修改</el-button>
    </div>
</template>

<script setup lang='ts'>
import { ref } from 'vue'
import { useTableInfo } from '/@/stores/ztable'
import { ElMessage } from 'element-plus'
const user = useTableInfo()

const modify = () => {
    if (!user.zTable.selectRows || user.zTable.selectRows.length == 0) {
        ElMessage.error("请选择数据");
    } else if (user.zTable.selectRows.length > 1) {
        ElMessage.error("请选择一条数据");
    } else {

        user.zTableFunEditShow = true


    }
}
</script>
<style lang='scss' scoped>
</style>